The Elder Scrolls Forums

TES Construction Set and Plugins >> General TES Construction Set

Pages: 1
Archived User Account

Baffling PositionCell problem
      #2878677 - 08/02/04 09:52 AM

I made a script to prevent people from cheating and teleporting to a certain cell in my mod, by placing this script on an activator at the spot they arrive at.

It catches the player so fast that they don't even see the cell they were trying to get to.

The problem is that they don't land at the spot I specified. Instead, they arrive in the void near the starting area of the cell I want them to land at.

I have double-checked the coordinates, and they SHOULD be arriving at the spot I specified, but they aren't.

I've used Player->PositionCell before to teleport players to certain spots in a different cell, and it's worked. I have no idea why this isn't working now.

Code:
begin stc_kwMaze_cheater

short mazedone

if (GetDistance Player <= 128)
if ( GetJournalIndex, "XZ_KwernerMaze00" == 25)
set mazedone to 1
endif

if ( GetJournalIndex, "XZ_KwernerMaze00" == 26)
set mazedone to 1
endif

if (mazedone != 1)
MessageBox "Cheaters don't prosper. Go away now!"
Player->PositionCell -5290, 6327, 13600, -90 "Kwerner Complex, Hall of Confusion"
endif
endif

end



Post Extras: Print Post   Remind Me!   Notify Moderator  
Mode_Locrian
Diviner

Reged: 10/07/02
Posts: 2084
Loc: Bjornholm, Rykith Lowlands Region
Re: Baffling PositionCell problem [Re: ]
      #2878765 - 08/02/04 10:47 AM

I've had similar problems with positionCell before. Here's a workaround that will offer the same functionality:

Player -> coc, "cell name"
player -> setpos, x, value
player -> setpos, y, value
player -> setpos, z, value

It's a shame that you need 4 lines to do the work of one, but that's the strategy I employed when positionCell wasn't working for me.

--------------------
My Website
Bards of Vvardenfell Thread (New Info 8/15/04)


Post Extras: Print Post   Remind Me!   Notify Moderator  
Archived User Account

Re: Baffling PositionCell problem [Re: Mode_Locrian]
      #2878865 - 08/02/04 11:33 AM

The four-line solution didn't have any effect at all. It's still not working.

Post Extras: Print Post   Remind Me!   Notify Moderator  
Mode_Locrian
Diviner

Reged: 10/07/02
Posts: 2084
Loc: Bjornholm, Rykith Lowlands Region
Re: Baffling PositionCell problem [Re: ]
      #2879079 - 08/02/04 01:09 PM

Hmm... well that's odd. I'm assuming that you get the messageBox there, but you don't get teleported correctly.

Wait... is the activator that teleports you in the same cell that you get teleported to? If not, then my idea wouldn't work anyway, as you would only coc to the cell, but not have your position set.

--------------------
My Website
Bards of Vvardenfell Thread (New Info 8/15/04)


Post Extras: Print Post   Remind Me!   Notify Moderator  
Limorkil
Adept

Reged: 08/28/02
Posts: 388
Loc: Atlanta, Georgia, USA
Re: Baffling PositionCell problem [Re: Mode_Locrian]
      #2879197 - 08/02/04 01:43 PM

Make sure your negative coordinates only have one '-' sign before each number. I know this is a long shot but I had this problem in my script.

I was creating scripts to teleport the player to different locations based on the item equipped. This involved a lot of cutting and pasting, and the editing of scripts. In doing so I found there were two places where my negative sign was actually two '-' symbols together. This resulted in my character appearing in the wrong place. The script syntax checker does not detect this.

--------------------
Zorremalku the Dunmer Phantom Elite (Xbox)
Level: 18
High Skills: Short Blade (80) Mysticism (71) Destruction (64)
Factions: Temple(8), Telvanni(6), Mages(8), Morag Tong(7)
Current loc/activity: Stuck in Sadrith Mora for the moment while Limorkil's obsession with Leifang runs its course
Updated: 8/9/04

Post Extras: Print Post   Remind Me!   Notify Moderator  
ManaUser
Master

Reged: 05/31/00
Posts: 6115
Loc: Long Beach, CA, USA
Re: Baffling PositionCell problem [Re: Mode_Locrian]
      #2879198 - 08/02/04 01:44 PM

I assume you've aldready double-checked the co-ords? I think the best way is to place an NPC there, floating just flightly off the ground (because the game adjusts for floating, be sinking is bad), and check the NPC's location at the bottum of the screen,

Post Extras: Print Post   Remind Me!   Notify Moderator  
Monica21
Master

Reged: 01/16/03
Posts: 6109
Loc: D'Hara
Re: Baffling PositionCell problem [Re: ]
      #2879240 - 08/02/04 01:58 PM

I had a similar problem with a script I was trying to use. I think the problem is that everything is trying to execute at once, so you end up in a void. I had to end up using a framecnt variable so that the script would first have time to notice that the PC was in the cell, and then have time to teleport him back out:

Code:
Begin MMteleport


short doOnce
short framecnt


if ( doOnce == 0 )
if ( GetPCCell "Caldera, Ghorak Manor" == 1 )
if ( GetJournalIndex "MM_GhorakManor" < 20 )
"scamp_creeper"->positioncell 4549, 4402, 14265, 263 "Caldera, Ghorak Manor Basement"
set framecnt to framecnt + 1
if framecnt > 2
; coc caldera
Player -> positioncell -9888, 18523, 1460, 5 "Caldera"
set doOnce to 1
set framecnt to 0
endif
endif
endif
endif

if ( cellChanged == 1 )
set doOnce to 0
set framecnt to 0
;Player -> positioncell -9888, 18523, 1460, 5 "Caldera"
endif

End MMteleport



Hope that helps.

--------------------
ElricM Web Portal
Telesphoros' List 'o Mods
kwshipman's List of House Mods

Post Extras: Print Post   Remind Me!   Notify Moderator  
Archived User Account

Re: Baffling PositionCell problem [Re: Mode_Locrian]
      #2879245 - 08/02/04 01:59 PM

Quote:

Hmm... well that's odd. I'm assuming that you get the messageBox there, but you don't get teleported correctly.

Wait... is the activator that teleports you in the same cell that you get teleported to? If not, then my idea wouldn't work anyway, as you would only coc to the cell, but not have your position set.




I get the message box, and I get teleported to the right cell, but not the right place in the cell. The activator that teleports you is in the cell that the player is trying to cheat to go to, and it sends you to another cell.

I have checked the coordinates and destination carefully, it's not a double minus error. I used a decoration, put it on the floor and noted the coordinates. I've done that twice, and I still end up extremely far away.

I will check again, though, and swap the coordinates around to see if I have made a mistake.



Post Extras: Print Post   Remind Me!   Notify Moderator  
Archived User Account

Re: Baffling PositionCell problem [Re: Monica21]
      #2879834 - 08/02/04 04:49 PM

Quote:

I had a similar problem with a script I was trying to use. I think the problem is that everything is trying to execute at once, so you end up in a void. I had to end up using a framecnt variable so that the script would first have time to notice that the PC was in the cell, and then have time to teleport him back out:

Code:
Begin MMteleport


short doOnce
short framecnt


if ( doOnce == 0 )
if ( GetPCCell "Caldera, Ghorak Manor" == 1 )
if ( GetJournalIndex "MM_GhorakManor" < 20 )
"scamp_creeper"->positioncell 4549, 4402, 14265, 263 "Caldera, Ghorak Manor Basement"
set framecnt to framecnt + 1
if framecnt > 2
; coc caldera
Player -> positioncell -9888, 18523, 1460, 5 "Caldera"
set doOnce to 1
set framecnt to 0
endif
endif
endif
endif

if ( cellChanged == 1 )
set doOnce to 0
set framecnt to 0
;Player -> positioncell -9888, 18523, 1460, 5 "Caldera"
endif

End MMteleport



Hope that helps.




Thank you, adding the delay solved the problem.

Post Extras: Print Post   Remind Me!   Notify Moderator  
Pages: 1


Extra information
1 registered and 4 anonymous users are browsing this forum.

Moderator:  Umrahel, Freddo, Pete, Hungry Donner, Attrebus, Miltiades, tegger 

Print Thread

Permissions
      You cannot start new topics
      You cannot reply to topics
      HTML is disabled
      UBBCode is enabled

Rating:
Thread views: 90

Rate this thread
 
Jump to

The Elder Scrolls Homepage

*
UBB.threads™ 6.3

Click for Privacy Statement © 2003 Bethesda Softworks LLC, a ZeniMax Media company. All Rights Reserved.
PRIVACY POLICY | TERMS & CONDITIONS | LEGAL INFORMATION | CONTACT US